import { Module } from '@nestjs/common';
import { TypeOrmModule, TypeOrmModuleOptions } from '@nestjs/typeorm';
import { config } from '../config';
import { BotModule } from './bot/bot.module';
import { UserModule } from './user/user.module';
import { RabbitModule } from './rabbitMQ/rabbit.module';
import { CronModule } from './cron/cron.module';
import { TraderModule } from './trader/trader.module';
import { TelegramBotModule } from './telegram-bot/telegram-bot.module';

@Module({
	imports: [
		TypeOrmModule.forRoot(<TypeOrmModuleOptions>config.database),
		UserModule,
		BotModule,
		RabbitModule,
		CronModule,
		TraderModule,
		TelegramBotModule,
	],
	controllers: [],
	providers: [],
	exports: [],
})
export class AppModule {}
